package service.Impl;

import dao.Impl.ProductDaoImpl;
import dao.ProductDao;
import entity.Product;
import service.ProductService;

import java.util.List;

/**
 * @author 陪你度过漫长岁月
 */
public class ProductServiceImpl implements ProductService {
    ProductDao productDao = new ProductDaoImpl();

    @Override
    public List<Product> listProduct() {
        return productDao.listProduct();
    }

    @Override
    public int addProduct(Product product) {
        return productDao.addProduct(product);
    }

    @Override
    public Product pid(int id) {
        return productDao.pid(id);
    }

    @Override
    public int delete(int id) {
        return productDao.delete(id);
    }
}
